/***************************************************************************
 * 
 * Copyright (c) 2011 Baidu.com, Inc. All Rights Reserved
 * common.h,v 1.0 2012-08-17 11:31 yelu01 
 * 
 **************************************************************************/
 
 
 
/**
 * @file log.h
 * @author yelu01(yelu01@baidu.com)
 * @date 2012-08-17 11:31
 * @version 1.0 
 * @brief wrapper of com_log
 *  
 **/

#pragma once

#include "com_log.h"

#ifndef NOLOG
#define LOG(_level_, _fmt_, args...) \
    do\
    {\
        com_writelog(_level_,"[%s][%d][%s]"_fmt_,  __FILE__, __LINE__, __FUNCTION__,##args);\
    }while(false)
#else
#define LOG(_level_, _fmt_, args...) do{}while(false)
#endif

#define WARNING COMLOG_WARNING
#define DEBUG COMLOG_DEBUG
#define INFO COMLOG_INFO
#define FATAL COMLOG_FATAL
